package org.springblade.modules.repair.dto.statistical;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.Max;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;
import java.util.Date;
import java.util.List;

/**
 * @Description 工单作业统计分析入参
 * @Author ysq
 * @Date 2022/8/24
 **/
@Data
public class WorkStatisticalDTO {

	@ApiModelProperty("用户列表")
	private List<Long> userIds;

	@NotNull(message = "开始时间不能为空")
	@JsonFormat(pattern = "yyyy-MM-dd")
	@ApiModelProperty(value = "开始时间")
	private Date beginDate;

	@NotNull(message = "结束时间不能为空")
	@JsonFormat(pattern = "yyyy-MM-dd")
	@ApiModelProperty(value = "结束时间")
	private Date endDate;

	@Min(value = 0, message = "维度类型值异常")
	@Max(value = 2, message = "维度类型值异常")
	@ApiModelProperty(value = "维度：0-日，1-周，2-月")
	private Integer dimension;

	@ApiModelProperty(value = "类型 1: 保养, 2: 维修, 4: 部件更换")
	private Integer type;
}
